import request from "@/utils/request";

export const getAllProjects = (params,data) => {
    return request({
        url: "/project/getAllProjects",
        method: "POST",
        params:params,
        data
    });
};
// export const getAllProjects = (data) => {
//     return request({
//         url: "/project/getAllProjects",
//         method: "POST",
//         data,
//     });
// };

export const createProject = (data) => {
    return request({
        url: "/project/createProject",
        method: "POST",
        data,
    });
};

export const getAllTask = (data) => {
    return request({
        url: "/task/getAllTask",
        method: "POST",
        data,
    });
};

export const addTask = (data) => {
    return request({
        url: "/task/getAllTask",
        method: "POST",
        data,
    });
};

export const updateTaskStatus = (params) => {
    return request({
        url: "/task/updateTaskStatus",
        method: "GET",
        params: params,
    });
};

export const giveTask = (data) => {
    return request({
        url: "/task/giveTask",
        method: "POST",
        data,
    });
};

export const getAllGroup = (params,data) => {
    return request({
        url: "/group/getAllGroup",
        method: "POST",
        params:params,
        data
    });
};